package com.software.graduationproject.modules.comment.object;

import cn.hutool.core.date.DatePattern;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.software.graduationproject.modules.comment.entity.Comment;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

/**
 * CommentVo : 评论表
 * ---------------------------------------------------------------------------------------------------------------------
 */
@Data
@NoArgsConstructor
@EqualsAndHashCode(callSuper = true)
public class CommentVo extends Comment {

    private Long merchantId;

    private String foodName;

    private String merchantName;

    private String merchantImg;

    @JsonFormat(pattern = DatePattern.NORM_DATE_PATTERN, timezone = "GMT+8")
    @DateTimeFormat(pattern = DatePattern.NORM_DATE_PATTERN)
    private Date commentTime;

}
